import Vue from 'vue'
import VueRouter from 'vue-router'
import HomePage from '@/pages/home/home.vue'

Vue.use(VueRouter)

const routes = [
	{
		path: '/',
		name: 'Home',
		component: HomePage
	},
	// 在路由配置中添加
	{
		path: '/auth',
		name: 'Auth',
		component: () => import('@/pages/auth/AuthPage.vue')
	},
	{
		path: '/exam',
		name: 'Exam',
		component: () => import('@/pages/exam/ExamPage.vue')
	},
	{
		path: '/chatexam',
		name: 'chatExam',
		component: () => import('@/pages/chat/ChatExam.vue')
	}
]

const router = new VueRouter({
	mode: 'history',
	base: process.env.BASE_URL,
	routes
})

export default router
